package com.xyz.study.design_mode.k_composite.mode;

/**
 * 角色：Leaf 树叶
 * @author XYZ
 * @version 1.0.0
 * @since 2021-01-27 18:34
 */
public class File extends Entry{
    private String name;

    private int size;

    public File(String name, int size) {
        this.name = name;
        this.size = size;
    }

    @Override
    public String getName() {
        return name;
    }

    @Override
    public int getSize() {
        return size;
    }
}
